.class public Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;
.super Landroid/widget/FrameLayout;
.source "MergeVideoImagePreviewController.java"

# interfaces
.implements Landroid/widget/SeekBar$OnSeekBarChangeListener;


# instance fields
.field public a:Landroid/content/Context;

.field private b:Ljava/lang/StringBuilder;

.field private c:Ljava/util/Formatter;

.field private d:Landroid/widget/ImageView;

.field private e:Landroid/widget/SeekBar;

.field private f:Landroid/widget/TextView;

.field private g:Landroid/widget/TextView;

.field private h:Landroid/widget/ImageView;

.field private i:Landroid/widget/TextView;

.field private j:Les/re;

.field private k:I


# direct methods
.method public constructor <init>(Landroid/content/Context;)V
    .locals 1

    const/4 v0, 0x0

    .line 1
    invoke-direct {p0, p1, v0}, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V

    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
    .locals 1

    const/4 v0, 0x0

    .line 2
    invoke-direct {p0, p1, p2, v0}, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V

    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
    .locals 0

    .line 3
    invoke-direct {p0, p1, p2, p3}, Landroid/widget/FrameLayout;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V

    .line 4
    iput-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->a:Landroid/content/Context;

    .line 5
    new-instance p1, Ljava/lang/StringBuilder;

    invoke-direct {p1}, Ljava/lang/StringBuilder;-><init>()V

    iput-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->b:Ljava/lang/StringBuilder;

    .line 6
    new-instance p1, Ljava/util/Formatter;

    iget-object p2, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->b:Ljava/lang/StringBuilder;

    invoke-static {}, Ljava/util/Locale;->getDefault()Ljava/util/Locale;

    move-result-object p3

    invoke-direct {p1, p2, p3}, Ljava/util/Formatter;-><init>(Ljava/lang/Appendable;Ljava/util/Locale;)V

    iput-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->c:Ljava/util/Formatter;

    const/4 p1, 0x1

    .line 7
    invoke-virtual {p0, p1}, Landroid/widget/FrameLayout;->setFitsSystemWindows(Z)V

    .line 8
    invoke-virtual {p0}, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->a()V

    return-void
.end method

.method private b(I)Ljava/lang/String;
    .locals 9

    .line 1
    div-int/lit8 v0, p1, 0x64

    rem-int/lit8 v0, v0, 0xa

    .line 2
    div-int/lit16 p1, p1, 0x3e8

    .line 3
    rem-int/lit8 v1, p1, 0x3c

    .line 4
    div-int/lit8 v2, p1, 0x3c

    rem-int/lit8 v2, v2, 0x3c

    .line 5
    div-int/lit16 p1, p1, 0xe10

    .line 6
    iget-object v3, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->b:Ljava/lang/StringBuilder;

    const/4 v4, 0x0

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->setLength(I)V

    const/4 v3, 0x2

    const/4 v5, 0x1

    const/4 v6, 0x3

    if-lez p1, :cond_0

    .line 7
    iget-object v7, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->c:Ljava/util/Formatter;

    const/4 v8, 0x4

    new-array v8, v8, [Ljava/lang/Object;

    invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object p1

    aput-object p1, v8, v4

    invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object p1

    aput-object p1, v8, v5

    invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object p1

    aput-object p1, v8, v3

    invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object p1

    aput-object p1, v8, v6

    const-string p1, "%d:%02d:%02d.%1d"

    invoke-virtual {v7, p1, v8}, Ljava/util/Formatter;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/util/Formatter;

    move-result-object p1

    invoke-virtual {p1}, Ljava/util/Formatter;->toString()Ljava/lang/String;

    move-result-object p1

    return-object p1

    .line 8
    :cond_0
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->c:Ljava/util/Formatter;

    new-array v6, v6, [Ljava/lang/Object;

    invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v2

    aput-object v2, v6, v4

    invoke-static {v1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v1

    aput-object v1, v6, v5

    invoke-static {v0}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;

    move-result-object v0

    aput-object v0, v6, v3

    const-string v0, "%02d:%02d.%1d"

    invoke-virtual {p1, v0, v6}, Ljava/util/Formatter;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/util/Formatter;

    move-result-object p1

    invoke-virtual {p1}, Ljava/util/Formatter;->toString()Ljava/lang/String;

    move-result-object p1

    return-object p1
.end method


# virtual methods
.method protected a()V
    .locals 2

    .line 1
    iget-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->a:Landroid/content/Context;

    sget v1, Les/y4;->durec_video_edit_preview_controller_layout:I

    invoke-static {v0, v1, p0}, Landroid/view/View;->inflate(Landroid/content/Context;ILandroid/view/ViewGroup;)Landroid/view/View;

    .line 2
    sget v0, Les/x4;->media_controller_back:I

    invoke-virtual {p0, v0}, Landroid/widget/FrameLayout;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/ImageView;

    iput-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->h:Landroid/widget/ImageView;

    .line 3
    sget v0, Les/x4;->media_controller_save:I

    invoke-virtual {p0, v0}, Landroid/widget/FrameLayout;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/TextView;

    iput-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->i:Landroid/widget/TextView;

    .line 4
    sget v0, Les/x4;->media_controller_pause:I

    invoke-virtual {p0, v0}, Landroid/widget/FrameLayout;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/ImageView;

    iput-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->d:Landroid/widget/ImageView;

    .line 5
    new-instance v1, Lcom/esfile/screen/recorder/videos/merge/ui/f;

    invoke-direct {v1, p0}, Lcom/esfile/screen/recorder/videos/merge/ui/f;-><init>(Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;)V

    invoke-virtual {v0, v1}, Landroid/widget/ImageView;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    .line 6
    sget v0, Les/x4;->media_controller_progress:I

    invoke-virtual {p0, v0}, Landroid/widget/FrameLayout;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/SeekBar;

    iput-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->e:Landroid/widget/SeekBar;

    .line 7
    invoke-virtual {v0, p0}, Landroid/widget/SeekBar;->setOnSeekBarChangeListener(Landroid/widget/SeekBar$OnSeekBarChangeListener;)V

    .line 8
    sget v0, Les/x4;->media_controller_cur_time:I

    invoke-virtual {p0, v0}, Landroid/widget/FrameLayout;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/TextView;

    iput-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->f:Landroid/widget/TextView;

    .line 9
    sget v0, Les/x4;->media_controller_total_time:I

    invoke-virtual {p0, v0}, Landroid/widget/FrameLayout;->findViewById(I)Landroid/view/View;

    move-result-object v0

    check-cast v0, Landroid/widget/TextView;

    iput-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->g:Landroid/widget/TextView;

    return-void
.end method

.method public synthetic a(I)V
    .locals 1

    .line 22
    iput p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->k:I

    const/4 v0, 0x2

    if-ne p1, v0, :cond_0

    .line 23
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->d:Landroid/widget/ImageView;

    sget v0, Les/w4;->durec_media_controller_pause_selector:I

    invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setImageResource(I)V

    goto :goto_0

    :cond_0
    const/4 v0, 0x1

    if-ne p1, v0, :cond_1

    .line 24
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->d:Landroid/widget/ImageView;

    sget v0, Les/w4;->durec_media_controller_play_selector:I

    invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setImageResource(I)V

    goto :goto_0

    :cond_1
    if-nez p1, :cond_2

    .line 25
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->d:Landroid/widget/ImageView;

    sget v0, Les/w4;->durec_media_controller_play_selector:I

    invoke-virtual {p1, v0}, Landroid/widget/ImageView;->setImageResource(I)V

    :cond_2
    :goto_0
    return-void
.end method

.method public synthetic a(IZ)V
    .locals 1

    .line 20
    iget-object p2, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->f:Landroid/widget/TextView;

    invoke-direct {p0, p1}, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->b(I)Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p2, v0}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    .line 21
    iget-object p2, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->e:Landroid/widget/SeekBar;

    invoke-virtual {p2, p1}, Landroid/widget/SeekBar;->setProgress(I)V

    return-void
.end method

.method public synthetic a(Landroid/view/View;)V
    .locals 2

    .line 10
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->j:Les/re;

    if-eqz p1, :cond_2

    .line 11
    iget v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->k:I

    const/4 v1, 0x2

    if-ne v0, v1, :cond_0

    .line 12
    invoke-virtual {p1}, Les/re;->f()V

    goto :goto_0

    :cond_0
    const/4 v1, 0x1

    if-ne v0, v1, :cond_1

    .line 13
    invoke-virtual {p1}, Les/re;->h()V

    goto :goto_0

    :cond_1
    if-nez v0, :cond_2

    .line 14
    invoke-virtual {p1}, Les/re;->h()V

    :cond_2
    :goto_0
    return-void
.end method

.method public a(Les/re;)V
    .locals 3

    .line 15
    iput-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->j:Les/re;

    .line 16
    new-instance v0, Lcom/esfile/screen/recorder/videos/merge/ui/d;

    invoke-direct {v0, p0}, Lcom/esfile/screen/recorder/videos/merge/ui/d;-><init>(Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;)V

    invoke-virtual {p1, v0}, Les/re;->a(Les/se;)V

    .line 17
    iget-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->e:Landroid/widget/SeekBar;

    invoke-virtual {p1}, Les/re;->b()J

    move-result-wide v1

    long-to-int v2, v1

    invoke-virtual {v0, v2}, Landroid/widget/SeekBar;->setMax(I)V

    .line 18
    iget-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->g:Landroid/widget/TextView;

    invoke-virtual {p1}, Les/re;->b()J

    move-result-wide v1

    long-to-int p1, v1

    invoke-direct {p0, p1}, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->b(I)Ljava/lang/String;

    move-result-object p1

    invoke-virtual {v0, p1}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    .line 19
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->j:Les/re;

    new-instance v0, Lcom/esfile/screen/recorder/videos/merge/ui/e;

    invoke-direct {v0, p0}, Lcom/esfile/screen/recorder/videos/merge/ui/e;-><init>(Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;)V

    invoke-virtual {p1, v0}, Les/re;->a(Les/re$e;)V

    return-void
.end method

.method public onProgressChanged(Landroid/widget/SeekBar;IZ)V
    .locals 0

    if-nez p3, :cond_0

    return-void

    :cond_0
    if-ltz p2, :cond_3

    .line 1
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->e:Landroid/widget/SeekBar;

    invoke-virtual {p1}, Landroid/widget/SeekBar;->getMax()I

    move-result p1

    if-le p2, p1, :cond_1

    goto :goto_0

    .line 2
    :cond_1
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->j:Les/re;

    if-nez p1, :cond_2

    return-void

    .line 3
    :cond_2
    invoke-virtual {p1, p2}, Les/re;->a(I)V

    .line 4
    iget-object p1, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->f:Landroid/widget/TextView;

    invoke-direct {p0, p2}, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->b(I)Ljava/lang/String;

    move-result-object p2

    invoke-virtual {p1, p2}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    :cond_3
    :goto_0
    return-void
.end method

.method public onStartTrackingTouch(Landroid/widget/SeekBar;)V
    .locals 0

    return-void
.end method

.method public onStopTrackingTouch(Landroid/widget/SeekBar;)V
    .locals 0

    return-void
.end method

.method public setOnBackClickListener(Landroid/view/View$OnClickListener;)V
    .locals 1

    if-eqz p1, :cond_0

    .line 1
    iget-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->h:Landroid/widget/ImageView;

    invoke-virtual {v0, p1}, Landroid/widget/ImageView;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    :cond_0
    return-void
.end method

.method public setOnSaveClickListener(Landroid/view/View$OnClickListener;)V
    .locals 1

    if-eqz p1, :cond_0

    .line 1
    iget-object v0, p0, Lcom/esfile/screen/recorder/videos/merge/ui/MergeVideoImagePreviewController;->i:Landroid/widget/TextView;

    invoke-virtual {v0, p1}, Landroid/widget/TextView;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    :cond_0
    return-void
.end method
